/**  
* @project_name mfq_comm
* @Title: ChannelStatus.java
* @Package com.yjd.comm.enums
* @Description: TODO
* @author renbangjie renbangjie@126.com  
* @date 2014-8-28 下午1:37:28
* @version V1.0  
* <b>Copyright (c)</b> 2014医信金融信息服务（上海）有限公司-版权所有<br/>
*/
package com.yjd.comm.enums;


/**
 * @ClassName: ChannelStatus
 * @Description: 充值渠道的状态
 * @author renbangjie renbangjie@126.com
 * @date 2014-8-28 下午1:37:28
 */
public enum ChannelStatus {
	
	enabled(1, "启用"),
	disable(2, "不可用");
	
	
	private ChannelStatus(int code, String label) {
		this.code = code;
		this.label = label;
	}
	
	public static ChannelStatus getInstance(Integer code){
		for (ChannelStatus status : ChannelStatus.values()) {
			if(status.getCode() == (int)code){
				return status;
			}
		}
		return null;
	}
	

	private int code;
	
	private String label;

	public int getCode() {
		return code;
	}

	public void setCode(int code) {
		this.code = code;
	}

	public String getLabel() {
		return label;
	}

	public void setLabel(String label) {
		this.label = label;
	}
	
	
	
}
